From 3255afe90de4d0afca21c002018406e478ed02db Mon Sep 17 00:00:00 2001 From: mcarton Date: Fri, 15 Jan 2016 15:51:23 +0100 Subject: [PATCH] Remove useless lifetimes MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Fix all Clippy’s needless_lifetimes warnings. --- src/cargo/lib.rs | 2 +- src/cargo/ops/cargo_rustc/layout.rs | 6 +++--- src/cargo/sources/git/utils.rs | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/src/cargo/lib.rs b/src/cargo/lib.rs index 9e58786ca..8a4b4338d 100644 --- a/src/cargo/lib.rs +++ b/src/cargo/lib.rs @@ -241,7 +241,7 @@ pub fn version() -> String { }) } -fn flags_from_args<'a, T>(usage: &str, args: &[String], +fn flags_from_args(usage: &str, args: &[String], options_first: bool) -> CliResult where T: Decodable { diff --git a/src/cargo/ops/cargo_rustc/layout.rs b/src/cargo/ops/cargo_rustc/layout.rs index 5ab7bb5a4..6bf8b3e15 100644 --- a/src/cargo/ops/cargo_rustc/layout.rs +++ b/src/cargo/ops/cargo_rustc/layout.rs @@ -113,9 +113,9 @@ impl Layout { } } - pub fn dest<'a>(&'a self) -> &'a Path { &self.root } - pub fn deps<'a>(&'a self) -> &'a Path { &self.deps } - pub fn examples<'a>(&'a self) -> &'a Path { &self.examples } + pub fn dest(&self) -> &Path { &self.root } + pub fn deps(&self) -> &Path { &self.deps } + pub fn examples(&self) -> &Path { &self.examples } pub fn fingerprint(&self, package: &Package) -> PathBuf { self.fingerprint.join(&self.pkg_dir(package)) diff --git a/src/cargo/sources/git/utils.rs b/src/cargo/sources/git/utils.rs index 9973cd8a2..3da37717d 100644 --- a/src/cargo/sources/git/utils.rs +++ b/src/cargo/sources/git/utils.rs @@ -159,7 +159,7 @@ impl GitRemote { } impl GitDatabase { - fn path<'a>(&'a self) -> &'a Path { + fn path(&self) -> &Path { &self.path } -- 2.30.2